<%--
  Created by IntelliJ IDEA.
  User: 17728
  Date: 2020/10/23
  Time: 15:02
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib uri="http://java.sun.com/jstl/core_rt" prefix="c" %>
<html>
<head>
    <title>Title</title>
    <script type="text/javascript">
        $(function () {
            // 给 【删除】绑定单击事件
            $("a.deleteItem").click(function () {
                return confirm("你确定要删除 【" + $(this).parent().parent().find("td:first").text() + "】吗?")
            });
        });
    </script>
    <%@ include file="/pages/common/head.jsp" %>
    <style type="text/css">
        .n {
            width: 70vw;
            margin: 0 auto;
        }

        .a {
            width: 60vw;
            height: 550px;
            margin: 0 auto;
            position: relative;
            top: 30px;
        }

        .b {

            height: 480px;
        }

        .d {
            text-align: center;
            position: relative;
            bottom: 0px;

        }

    </style>
</head>
<body>
<div class="n">
    <nav>


        <!-- Collect the nav links, forms, and other content for toggling -->

    </nav>
</div>
<div class="a">
    <div class="b">
        <table align="center" class="table table-hover">
            <thead>
            <td colspan="6" align="center"><h3>学生提交的作业</h3></td>
            <tr align="center">
                <td>作业id</td>
                <td>学号</td>
                <td>学生</td>
                <td>分数</td>
                <td colspan="2">操作</td>
            </tr>
            </thead>
            <c:forEach items="${requestScope.studentHw}" var="studentHw">
                <tr align="center">
                    <td>${studentHw.hw_id}</td>
                    <td>${studentHw.sNo}</td>
                    <td>${studentHw.name}</td>
                    <td>${studentHw.status}</td>
                    <td><a href="HwStuServlet?action=downloadStuHw&id=${studentHw.hw_stu_attach_id}">下载</a></td>
                    <td><a href="HwStuServlet?action=deleteHwStu&id=${studentHw.id}&hw_id=${studentHw.hw_id}">删除</a>
                    </td>
                </tr>
            </c:forEach>


        </table>
    </div>

</div>
</body>
</html>

</body>
</html>
